//
//  HNSNProductListModel.m
//  ZYManagementSystem
//
//  Created by 星道 on 17/6/14.
//  Copyright © 2017年 焕宁. All rights reserved.
//

#import "HNSNProductListModel.h"

@implementation HNSNProductListModel


+ (instancetype)HN_ObjectWithKeyValus:(NSDictionary *)Dict
{
    return [[self alloc] initWithDict:Dict];
}


- (instancetype)initWithDict:(NSDictionary *)Dict
{
    if (self = [super init]) {

        [self setValuesForKeysWithDictionary:Dict];
    }
    return self;
}


- (void)setValue:(id)value forKey:(NSString *)key{

    if ([key isEqualToString:@"id"]) {
        self.ID = value;
    } else if ([key isEqualToString:@"user"]){
        self.username_Sub = value[@"username"];
        self.petName = value[@"petName"];
        self.uid = value[@"uid"];
    } else {
        [super setValue:value forKey:key];
    }
}

- (void)setValue:(id)value forUndefinedKey:(NSString *)key{
    
}
@end
